package cn.niit.letuseatdemo.service.impl;

import cn.niit.letuseatdemo.entity.domain.Admin;
import cn.niit.letuseatdemo.mapper.AdminMapper;
import cn.niit.letuseatdemo.service.AdminService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * @Description
 * @Author Zhang Shiqi
 * @CreateTime 2022/10/23 11:56
 */
@Service
public class AdminServiceImpl implements AdminService {
    @Autowired
    private AdminMapper adminMapper;

    /*
    * @Description:根据管理员的名字和密码查询，用于管理员登录
    * @Author: Zhang Shiqi
    * @CreateTime： 2022/10/30 23:49
     * @param: adminName
     * @param: adminPass
     * @return: cn.niit.letuseatdemo.entity.domain.Admin
    **/
    @Override
    public Admin getAdminByAdminNamePassword(String adminName, String adminPass) {
        return adminMapper.selectAdminByAdminNamePassword(adminName,adminPass);
    }
}
